package com.joysuch.wwyt.api.mh.controller;

import com.joysuch.wwyt.api.mh.service.MonitPointConfigService;
import com.joysuch.wwyt.config.RedisClient;
import com.joysuch.wwyt.core.common.ajax.ResultBean;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.io.IOException;

@Slf4j
@RestController
@RequestMapping("/mh/api")
@RequiredArgsConstructor(onConstructor = @__(@Autowired))
public class MhMonitPointConfigController {

    @Autowired
    private MonitPointConfigService monitPointConfigService;


    @GetMapping("/clearCache")
    public ResultBean userTaskList(String type){
        monitPointConfigService.clearCache(type);
        return ResultBean.defaultSuccessResult();
    }
}
